% ============================================================ %
% vec.m
%
% For a matrix A returns vec(A). (see Hamilton p. 265)
% ============================================================ % 

function v = vec(A);
  [m n] = size(A);
  v = [];
  for i = 1:n;
    v = [v;A(:,i)];
  end;
